<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8" name="viewport" content="width=device-width, initial-scale=1.0">
    <title>活动情况提交</title>
    <link href="/myTest/css/login.css" rel="stylesheet">
    <link href="/myTest/css/submission.css" rel="stylesheet">
</head>
<body>
<div>

    <div>
        <div>
            <img style="width: 100%" src="/myTest/bg/submission.png">

            <div class="dev" style="margin-top: 5px">
                <div class="dev_l">
                    活动标题
                </div>
                <div class="dev_r">
                    <input type="text"  placeholder="请输入标题">
                </div>
            </div>
            <div class="dev">
                <div class="dev_l">
                    活动地点
                </div>
                <div class="dev_r">
                    <input type="text"  placeholder="请输入地点">
                </div>
            </div>
            <div class="sub_dev">
                <div class="sub_dev_l">
                    活动详情
                </div>
                <div class="sub_dev_r" style="position: relative;z-index: 3">
                    <textarea style="position: absolute;z-index: 2;background-color: transparent"  id="detail2" placeholder="请输入活动详情"></textarea>
                    <p  class="number" style="z-index: 1; position: absolute;"><span id="detail3">0</span>/150</p>
                </div>
            </div>
            <div class="dev">
                <div class="dev_l" style="float: left; padding-top: 20px">
                    活动图片
                </div>
                <div class="sub_img">
                    <input type="image" src="/myTest/bg/add.png"  placeholder="">
                </div>
                <div class="sub_img">
                    <input type="image" src="/myTest/bg/add.png"  placeholder="">
                </div>
            </div>

        </div>
        <div style="margin-top: 50px ; text-align: center;">
            <button class="sub_btn" id="submit" style="color: white">提交</button>
        </div>


    </div>
</div>
<script src="/myTest/script/jquery.min.js"></script>
<!--<script>
    function textarealength(obj,maxlength){
        var v = $(obj).val();
        var l = v.length;
        if( l > maxlength){
            v = v.substring(0,maxlength);
            $(obj).val(v);
        }
        $(obj).parent().find(".textarea-length").text(v.length);
    }
</script>-->
<script>
    $(function () {
        var text2=$("#detail2").val();
        var counter2=text2.length;
        $("#detail3").text(counter2);
        $("#detail2").on('blur keyup input',function(){
            var text=$("#detail2").val();
            var counter=text.length;
            if(counter>150){
                /*alert("已超出限制")*/
                $('#detail2').disabled();
            }
            $("#detail3").text(counter);

        });

    })
</script>
<script>

</script>
</body>
</html>